For example , you can use the stack pointer to follow the stack 例如,可以使用堆栈指针跟踪堆栈。
Inline assembly can be written to determine the stack pointer 可以编写内联程序集( inline assembly )来确定栈指针。
On solaris , this sample code allows you to get the stack pointer 在solaris ,下面这段示例代码让您可以获取堆栈指针:
Getting the stack pointer 获得堆栈指针
Parameter is the offset from the stack pointer to the high - order part of the value 参数是距离值的高位部分堆栈指针的偏移量。
Set up stack pointer 设置堆栈指针
Parameter is the offset from the stack pointer to the low - order part of the value , and the 参数是距离值的低位部分堆栈指针的偏移量,
The stack pointer is not used at all in the function and changing its value is meaningless 堆栈指针根本不能这样使用,改变它的值是无意义的。
There are no push or pop instructions and no dedicated stack pointer register defined by the architecture 体系结构没有定义压入或者弹出指令,也没有定义专门的栈指针寄存器。
The eabi reserves gpr1 for a stack pointer , gpr3 - gpr7 for function argument passing , and gpr3 for function return values Eabi将gpr1预留为栈指针, gpr3到gpr7用于函数参数传递, gpr3用于函数返回值。